<div class="ui-g">
    <div class="ui-g-3" style="border-right: 1px solid #c8c8c8;">
        <div class="notice-detail-content">
            <div class="ui-g-12">
                <div class="ui-g-12">标题<span style="color:red;">*</span></div>
                <div class="ui-g-12">
                    <textarea rows="1" [(ngModel)]="title" pInputTextarea autoResize="true" [style]="{'width':'100%'}" (blur)="cleanMessage()"></textarea>
                    <div *ngIf="titleErrors">
                        <div class="form-valid-message">{{errorMessage}}</div>
                    </div>
                </div>
                <div class="ui-g-12">发布单位<span style="color:red;">*</span></div>
                <div class="ui-g-12">
                    <input pInputText type="text" [style]="{'width':'100%'}" [(ngModel)]="publishUnit" (blur)="cleanMessage()" />
                    <div *ngIf="publishUnitErrors">
                        <div class="form-valid-message">{{errorMessage}}</div>
                    </div>
                </div>
                <div class="ui-g-12">重要等级</div>
                <div class="ui-g-12">
                    <p-rating stars="5" [cancel]="false" [(ngModel)]="grade"></p-rating>
                </div>
                <div class="ui-g-12">附件</div>
                <div class="ui-g-12">
                    <div class="clearfix">
                        <nz-upload [nzAction]="onFileUpload()" [(nzFileList)]="noticeDocFileList" nzListType="picture" (nzChange)="noticeDocChange($event)">
                            <button nz-button><i nz-icon nzType="upload"></i><span>附件上传</span></button>
                        </nz-upload>
                    </div>
                </div>
                <div class="ui-g-12">收件人<span style="color:red;">*</span></div>
                <div class="ui-g-12">
                    <p-multiSelect [options]="roleTypes" [(ngModel)]="roleList" [panelStyle]="{width:'100%'}" defaultLabel="请选择收件人" [style]="{'width':'100%'}" (blur)="cleanMessage()"></p-multiSelect>
                    <div *ngIf="roleListErrors">
                        <div class="form-valid-message">{{errorMessage}}</div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <div class="ui-g-9 notice-content" style="height: 100%">
        <div class="ui-g-12" style="padding: 0px;max-height: 47px;">
            <div class="ui-g-6" style="margin-top: .5em">
                正文
            </div>
            <div class="ui-g-6" style="text-align: right">
                <button pButton type="button" icon="fa fa-paper-plane" label="发布" (click)="send()" [disabled]="isSendComplete" style="margin-right: 20px;"></button>
                <button pButton type="button" icon="fa fa-close" label="关闭" (click)="close()"></button>
            </div>
        </div>
        <div class="ui-g-12 notice-edit" style="height: calc(100% - 50px)">
        <p-editor [(ngModel)]="content" [style]="{'height': 'calc(100% - 60px)'}"></p-editor>
        </div>
    </div>
</div>
<p-confirmDialog #cd>
    <p-footer>
        <button type="button" pButton icon="fa fa-close" label="取消" (click)="reject()"></button>
        <button type="button" pButton icon="fa fa-check" label="确定" (click)="cd.accept()"></button>
    </p-footer>
</p-confirmDialog>
